home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MacHack 2000
/
MacHack 2000.toast
/
pc
/
The Hacks
/
Softshoe
/
Lisa's Mac Parts
/
Fonts
/
FontNumber.cp
< prev
next >
Wrap
Text File
|
2000-06-23
|
629b
|
37 lines
// FontNumber.cp
#ifndef FontNumber_h
#include "FontNumber.h"
#endif
#ifndef ConstPString_h
#include "ConstPString.h"
#endif
#include <Fonts.h>
FontNumber::FontNumber( int16 value )
: number( ( value == systemFont )
? System().Value()
: ( value == applFont )
? Application().Value()
: value )
{
}
FontNumber::FontNumber( ConstPString name )
{
GetFNum( name, &number );
}
FontNumber FontNumber::System()
{
static int16 font = GetSysFont();
return FontNumber( font );
}
FontNumber FontNumber::Application()
{
static int16 font = GetAppFont();
return FontNumber( font );
}